<h1>New rental</h1>

<% form_for(@rental) do |f| %>
  <%= f.error_messages %>

  <p>
    <%= f.label :pick_up %><br />
    <%= f.datetime_select :pick_up %>
  </p>
  <p>
    <%= f.label :return %><br />
    <%= f.datetime_select :return %>
  </p>
  <p>
    <%= f.label :book_id %><br />
    <%= f.text_field :book_id %>
  </p>
  <p>
    <%= f.label :user_id %><br />
    <%= f.text_field :user_id %>
  </p>
  <p>
    <%= f.submit "Create" %>
  </p>
<% end %>

<%= link_to 'Back', rentals_path %>
